#include "test_suite.h"
#include "cm_uart.h"
#include "cm_demo_uart.h"

#define SUITE_CMD_SIZE  300
#define SUITE_PRE_SIZE  10

/**命令结构体*/
typedef struct test_cmd {
    char * cmdstr;
    void (* cmdfunc)(unsigned char **,int);
} test_cmd_t;

typedef struct{
    unsigned char *case_cmd[10];
    int len;
    int ecec_time;
}module_cmd_t;

typedef struct{
    char name[20];
    char pre_con[50];
    module_cmd_t pre_exec[SUITE_PRE_SIZE];
    void (*pre_func)(unsigned char *cmd[],int len);
    void (*suite_func)(unsigned char *cmd[],int len);
    module_cmd_t suite_cmd[SUITE_CMD_SIZE];
}test_suite_cmd_t;

/*测试命令*/
test_suite_cmd_t test_adc_cmd = {
    .name = "adc",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_adc_operation,
    .suite_cmd = {{{"","ADC_OPERATION","READ","1"},4,50},{{"end"},1,0}},
};

test_suite_cmd_t test_aliyun_cmd = {
    .name = "aliyun",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_aliyun_operation,
    .suite_cmd = {{{"","ALIYUN_OPERATION","KEY_AUTH"},3,50},{{"","ALIYUN_OPERATION","CRED_AUTH"},3,50},{{"end"},1,0}},
};

extern int socket_arr[4];
test_suite_cmd_t test_asocket_cmd = {
    .name = "asocket",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_asocket_operation,
    .suite_cmd = {{{"","ASOCKET_OPERATION","ASOCKET_ELOOP"},3,50},{{"","ASOCKET_OPERATION","ASOCKET_OPEN_CONNECT","TCPIPV6","9000"},5,200},{{"","ASOCKET_OPERATION","ASOCKET_OPEN_CONNECT","TCPIPV4","9000"},5,200},{{"","ASOCKET_OPERATION","ASOCKET_OPEN_CONNECT","UDPIPV6","9001"},5,200},{{"","ASOCKET_OPERATION","ASOCKET_OPEN_CONNECT","UDPIPV4","9001"},5,200},{{"","ASOCKET_OPERATION","SUITE_SEND"},3,200},{{"","ASOCKET_OPERATION","SUITE_CLOSE"},3,20},{{"end"},1,0}},
};

test_suite_cmd_t test_async_dns_cmd = {
    .name = "async_dns",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_async_dns_operation,
    .suite_cmd = {{{"","ASYNC_DNS_OPERATION","GET_ELOOP"},3,200},{{"","ASYNC_DNS_OPERATION","INIT"},3,200},{{"","ASYNC_DNS_OPERATION","SET_PRIORITY","1"},4,200},{{"","ASYNC_DNS_OPERATION","REQUEST","www.sswwdd.top","IPV6"},5,200},{{"","ASYNC_DNS_OPERATION","REQUEST","www.sswwdd.top","IPV4"},5,200},{{"","ASYNC_DNS_OPERATION","REQUEST","www.sswwdd.top","IPV4V6"},5,200},{{"","ASYNC_DNS_OPERATION","REQUEST","www.sswwdd.top","IPV6V4"},5,200},{{"","ASYNC_DNS_OPERATION","REQUEST","iservice.10010.com","IPV6"},5,200},{{"","ASYNC_DNS_OPERATION","REQUEST","iservice.10010.com","IPV4"},5,200},{{"","ASYNC_DNS_OPERATION","REQUEST","iservice.10010.com","IPV4V6"},5,200},{{"","ASYNC_DNS_OPERATION","REQUEST","iservice.10010.com","IPV6V4"},5,200},{{"","ASYNC_DNS_OPERATION","SET_PRIORITY","0"},4,200},{{"","ASYNC_DNS_OPERATION","REQUEST","www.sswwdd.top","IPV6"},5,200},{{"","ASYNC_DNS_OPERATION","REQUEST","www.sswwdd.top","IPV4"},5,200},{{"","ASYNC_DNS_OPERATION","REQUEST","www.sswwdd.top","IPV4V6"},5,200},{{"","ASYNC_DNS_OPERATION","REQUEST","www.sswwdd.top","IPV6V4"},5,200},{{"","ASYNC_DNS_OPERATION","REQUEST","iservice.10010.com","IPV6"},5,200},{{"","ASYNC_DNS_OPERATION","REQUEST","iservice.10010.com","IPV4"},5,200},{{"","ASYNC_DNS_OPERATION","REQUEST","iservice.10010.com","IPV4V6"},5,200},{{"","ASYNC_DNS_OPERATION","REQUEST","iservice.10010.com","IPV6V4"},5,200},{{"end"},1,0}},
};

test_suite_cmd_t test_audio_play_cmd = {
    .name = "audio_play",
    .pre_con = "add play file",
    .pre_exec = {{{"","AUDIO_OPERATION","PLAY","FILE"},4,200},{{"end"},1,0}},
    .pre_func = cm_test_audio_operation,
    .suite_func = cm_test_audio_operation,
    .suite_cmd = {{{"","AUDIO_OPERATION","PLAY","VOLSET","0"},5,200},{{"","AUDIO_OPERATION","PLAY","VOLGET"},4,200},{{"","AUDIO_OPERATION","PLAY","VOLSET","10"},5,200},{{"","AUDIO_OPERATION","PLAY","VOLGET"},4,200},{{"","AUDIO_OPERATION","PLAY","FILEMP3"},4,660},{{"","AUDIO_OPERATION","PLAY","FILEAMR"},4,660},{{"","AUDIO_OPERATION","PLAY","STARTSTREAM"},4,200},{{"","AUDIO_OPERATION","PLAY","STREAMFRAME"},4,260},{{"","AUDIO_OPERATION","PLAY","STREAMFRAME"},4,260},{{"","AUDIO_OPERATION","PLAY","STOPSTREAM"},4,200},{{"","AUDIO_OPERATION","PLAY","FILEAMR"},4,200},{{"","AUDIO_OPERATION","PLAY","PAUSE"},4,200},{{"","AUDIO_OPERATION","PLAY","RESUME"},4,460},{{"","AUDIO_OPERATION","PLAY","FILEMP3"},4,360},{{"","AUDIO_OPERATION","PLAY","STOP"},4,660},\
{{"","AUDIO_OPERATION","PLAY","VOLSET","50"},5,200},{{"","AUDIO_OPERATION","PLAY","VOLGET"},4,200},{{"","AUDIO_OPERATION","PLAY","FILEMP3"},4,660},{{"","AUDIO_OPERATION","PLAY","FILEAMR"},4,660},{{"","AUDIO_OPERATION","PLAY","STARTSTREAM"},4,200},{{"","AUDIO_OPERATION","PLAY","STREAMFRAME"},4,260},{{"","AUDIO_OPERATION","PLAY","STREAMFRAME"},4,260},{{"","AUDIO_OPERATION","PLAY","STOPSTREAM"},4,200},{{"","AUDIO_OPERATION","PLAY","FILEAMR"},4,200},{{"","AUDIO_OPERATION","PLAY","PAUSE"},4,200},{{"","AUDIO_OPERATION","PLAY","RESUME"},4,460},{{"","AUDIO_OPERATION","PLAY","FILEMP3"},4,360},{{"","AUDIO_OPERATION","PLAY","STOP"},4,660},{{"end"},1,0},\
{{"","AUDIO_OPERATION","PLAY","VOLSET","100"},5,200},{{"","AUDIO_OPERATION","PLAY","VOLGET"},4,200},{{"","AUDIO_OPERATION","PLAY","FILEMP3"},4,660},{{"","AUDIO_OPERATION","PLAY","FILEAMR"},4,660},{{"","AUDIO_OPERATION","PLAY","STARTSTREAM"},4,200},{{"","AUDIO_OPERATION","PLAY","STREAMFRAME"},4,260},{{"","AUDIO_OPERATION","PLAY","STREAMFRAME"},4,260},{{"","AUDIO_OPERATION","PLAY","STOPSTREAM"},4,200},{{"","AUDIO_OPERATION","PLAY","FILEAMR"},4,200},{{"","AUDIO_OPERATION","PLAY","PAUSE"},4,200},{{"","AUDIO_OPERATION","PLAY","RESUME"},4,460},{{"","AUDIO_OPERATION","PLAY","FILEMP3"},4,360},{{"","AUDIO_OPERATION","PLAY","STOP"},4,660},{{"end"},1,0}},
};

test_suite_cmd_t test_audio_recorder_cmd = {
    .name = "audio_recorder",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_audio_operation,
    .suite_cmd = {{{"","AUDIO_OPERATION","RECORDER","PCMSTART"},4,260},{{"","AUDIO_OPERATION","RECORDER","STOP"},4,200},{{"","AUDIO_OPERATION","RECORDER","STARTSTREAMPCM"},4,200},{{"","AUDIO_OPERATION","RECORDER","STREAMFRAME"},4,260},{{"","AUDIO_OPERATION","RECORDER","STOPSTREAM"},4,200},\
    {{"","AUDIO_OPERATION","RECORDER","PCMSTART"},4,260},{{"","AUDIO_OPERATION","RECORDER","STARTSTREAMPCM"},4,200},{{"","AUDIO_OPERATION","RECORDER","STREAMFRAME"},4,260},{{"","AUDIO_OPERATION","RECORDER","STREAMFRAME"},4,260},{{"","AUDIO_OPERATION","RECORDER","STOP"},4,200},{{"","AUDIO_OPERATION","RECORDER","STOPSTREAM"},4,200},\
    {{"","AUDIO_OPERATION","RECORDER","AMR1220START"},4,2300},{{"","AUDIO_OPERATION","RECORDER","STARTSTREAMAMR"},4,200},{{"","AUDIO_OPERATION","RECORDER","STREAMFRAME"},4,2300},{{"","AUDIO_OPERATION","RECORDER","STREAMFRAME"},4,2300},{{"","AUDIO_OPERATION","RECORDER","STOP"},4,200},{{"","AUDIO_OPERATION","RECORDER","STOPSTREAM"},4,200},\
    {{"","AUDIO_OPERATION","RECORDER","AMR1020START"},4,2700},{{"","AUDIO_OPERATION","RECORDER","STOP"},4,200},{{"","AUDIO_OPERATION","RECORDER","STARTSTREAMAMR"},4,200},{{"","AUDIO_OPERATION","RECORDER","STREAMFRAME"},4,2700},{{"","AUDIO_OPERATION","RECORDER","STOPSTREAM"},4,200},\
    {{"","AUDIO_OPERATION","RECORDER","AMR795START"},4,3100},{{"","AUDIO_OPERATION","RECORDER","STOP"},4,200},{{"","AUDIO_OPERATION","RECORDER","STARTSTREAMAMR"},4,200},{{"","AUDIO_OPERATION","RECORDER","STREAMFRAME"},4,3100},{{"","AUDIO_OPERATION","RECORDER","STOPSTREAM"},4,200},\
    {{"","AUDIO_OPERATION","RECORDER","AMR740START"},4,3500},{{"","AUDIO_OPERATION","RECORDER","STOP"},4,200},{{"","AUDIO_OPERATION","RECORDER","STARTSTREAMAMR"},4,200},{{"","AUDIO_OPERATION","RECORDER","STREAMFRAME"},4,3500},{{"","AUDIO_OPERATION","RECORDER","STOPSTREAM"},4,200},\
    {{"","AUDIO_OPERATION","RECORDER","AMR670START"},4,3900},{{"","AUDIO_OPERATION","RECORDER","STOP"},4,200},{{"","AUDIO_OPERATION","RECORDER","STARTSTREAMAMR"},4,200},{{"","AUDIO_OPERATION","RECORDER","STREAMFRAME"},4,3900},{{"","AUDIO_OPERATION","RECORDER","STOPSTREAM"},4,200},\
    {{"","AUDIO_OPERATION","RECORDER","AMR590START"},4,4300},{{"","AUDIO_OPERATION","RECORDER","STOP"},4,200},{{"","AUDIO_OPERATION","RECORDER","STARTSTREAMAMR"},4,200},{{"","AUDIO_OPERATION","RECORDER","STREAMFRAME"},4,4300},{{"","AUDIO_OPERATION","RECORDER","STOPSTREAM"},4,200},\
    {{"","AUDIO_OPERATION","RECORDER","AMR515START"},4,4700},{{"","AUDIO_OPERATION","RECORDER","STOP"},4,200},{{"","AUDIO_OPERATION","RECORDER","STARTSTREAMAMR"},4,200},{{"","AUDIO_OPERATION","RECORDER","STREAMFRAME"},4,4700},{{"","AUDIO_OPERATION","RECORDER","STOPSTREAM"},4,200},\
    {{"","AUDIO_OPERATION","RECORDER","AMR475START"},4,5000},{{"","AUDIO_OPERATION","RECORDER","STOP"},4,200},{{"","AUDIO_OPERATION","RECORDER","STARTSTREAMAMR"},4,200},{{"","AUDIO_OPERATION","RECORDER","STREAMFRAME"},4,5000},{{"","AUDIO_OPERATION","RECORDER","STOPSTREAM"},4,200},\
    {{"end"},1,0}},
};

test_suite_cmd_t test_eloop_cmd = {
    .name = "eloop",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_eloop_operation,
    .suite_cmd = {{{"","ELOOP_OPERATION","HEAP"},3,300},{{"end"},1,0}},
};


test_suite_cmd_t test_fs_cmd = {
    .name = "fs",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_fs_operation,
    .suite_cmd = {{{"","FS_OPERATION","GET_INFO"},3,200},{{"","FS_OPERATION","OPEN","CM_WB","test1.txt"},5,200},{{"","FS_OPERATION","WRITE","1","17","123456789ABC0DEFG"},6,200},{{"","FS_OPERATION","SEEK","1","0","0"},6,200},{{"","FS_OPERATION","READ","1","17"},5,200},{{"","FS_OPERATION","SEEK","1","5","0"},6,200},{{"","FS_OPERATION","READ","1","3"},5,200},{{"","FS_OPERATION","SEEK","1","2","1"},6,200},{{"","FS_OPERATION","READ","1","3"},5,200},{{"","FS_OPERATION","CLOSE","1"},4,200},{{"","FS_OPERATION","EXIST","test1.txt"},4,200},{{"","FS_OPERATION","MOVE","test1.txt","test5.txt"},5,200},{{"","FS_OPERATION","EXIST","test5.txt"},4,200},{{"","FS_OPERATION","DEL","test5.txt"},4,200},\
{{"","FS_OPERATION","OPEN","CM_WBPLUS","test1.txt"},5,200},{{"","FS_OPERATION","WRITE","1","17","123456789ABC0DEFG"},6,200},{{"","FS_OPERATION","SEEK","1","0","0"},6,200},{{"","FS_OPERATION","READ","1","17"},5,200},{{"","FS_OPERATION","CLOSE","1"},4,200},{{"","FS_OPERATION","OPEN","CM_AB","test1.txt"},5,200},{{"","FS_OPERATION","WRITE","1","17","123456789ABC0DEFG"},6,200},{{"","FS_OPERATION","SEEK","1","0","0"},6,200},{{"","FS_OPERATION","READ","1","34"},5,200},{{"","FS_OPERATION","CLOSE","1"},4,200},\
{{"","FS_OPERATION","OPEN","CM_AB","test1.txt"},5,200},{{"","FS_OPERATION","SEEK","1","0","0"},6,200},{{"","FS_OPERATION","READ","1","17"},5,200},{{"","FS_OPERATION","CLOSE","1"},4,200},{{"","FS_OPERATION","OPEN","CM_AB","test1.txt"},5,200},{{"","FS_OPERATION","WRITE","1","17","123456789ABC0DEFG"},6,200},{{"","FS_OPERATION","SEEK","1","0","0"},6,200},{{"","FS_OPERATION","READ","1","34"},5,200},{{"","FS_OPERATION","CLOSE","1"},4,200},\
{{"","FS_OPERATION","OPEN","CM_RB","test1.txt"},5,200},{{"","FS_OPERATION","SEEK","1","0","0"},6,200},{{"","FS_OPERATION","READ","1","20"},5,200},{{"","FS_OPERATION","CLOSE","1"},4,200},\
{{"","FS_OPERATION","OPEN","CM_ABPLUS","test1.txt"},5,200},{{"","FS_OPERATION","WRITE","1","17","123456789ABC0DEFG"},6,200},{{"","FS_OPERATION","SEEK","1","0","0"},6,200},{{"","FS_OPERATION","READ","1","100"},5,200},{{"","FS_OPERATION","CLOSE","1"},4,200},\
{{"","FS_OPERATION","OPEN","CM_RBPLUS","test1.txt"},5,100},{{"","FS_OPERATION","WRITE","1","17","123456789ABC0DEFG"},6,100},{{"","FS_OPERATION","SEEK","1","0","0"},6,100},{{"","FS_OPERATION","READ","1","100"},5,100},{{"","FS_OPERATION","SEEK","1","10","0"},6,100},{{"","FS_OPERATION","WRITE","1","17","123456789ABC0DEFG"},6,100},{{"","FS_OPERATION","SEEK","1","10","0"},6,100},{{"","FS_OPERATION","READ","1","100"},5,100},{{"","FS_OPERATION","CLOSE","1"},4,100},\
{{"end"},1,0}},
};

test_suite_cmd_t test_ftp_cmd = {
    .name = "ftp",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_ftp_operation,
    .suite_cmd = {{{"","FTP_OPERATION","STATE"},3,200},{{"","FTP_OPERATION","OPEN","0"},4,400},{{"","FTP_OPERATION","STATE"},3,200},{{"","FTP_OPERATION","PUT","/ml307a_ftp_test.txt","20","1234567890abcdefghij","1"},7,300},{{"","FTP_OPERATION","GET_FILE","/ml307a_ftp_test.txt","8","10000"},6,200},{{"","FTP_OPERATION","GET_SIZE","/ml307a_ftp_test.txt"},4,200},\
{{"","FTP_OPERATION","PUT","/ml307a_ftp_test1.txt","20","1234567890abcdefghij","0"},7,200},{{"","FTP_OPERATION","GET_FILE","/ml307a_ftp_test1.txt","8","10"},6,200},{{"","FTP_OPERATION","RENAME_FILE","/ml307a_ftp_test1.txt","/ml307a_ftp_test2.txt"},5,200},{{"","FTP_OPERATION","DELETE_FILE","/ml307a_ftp_test2.txt"},4,200},\
{{"","FTP_OPERATION","MK_DIR","/dir_1","/dir_2"},5,200},{{"","FTP_OPERATION","MK_DIR","/dir_1/test1","/dir_2/test2"},5,200},{{"","FTP_OPERATION","FIND_FIRST","/dir_2"},4,200},{{"","FTP_OPERATION","FIND_NEXT"},3,200},{{"","FTP_OPERATION","FIND_NEXT"},3,200},{{"","FTP_OPERATION","FIND_CLOSE"},3,200},{{"","FTP_OPERATION","RM_DIR","/dir_2/test2"},4,200},{{"","FTP_OPERATION","RM_DIR","/dir_2"},4,200},{{"","FTP_OPERATION","SET_GET_CUR_DIR","/dir_1","/dir_1/test1"},5,200},{{"","FTP_OPERATION","RM_DIR","/dir_1/test1"},4,200},{{"","FTP_OPERATION","RM_DIR","/dir_1"},4,200},\
{{"","FTP_OPERATION","CLOSE"},3,200},\
{{"end"},1,0}},
};


test_suite_cmd_t test_http_cmd = {
    .name = "http",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_http_operation,
    .suite_cmd = {
{{"","HTTP_OPERATION","URI_ENCODE_COMPONENT","http://www.taobao.com/"},4,200},{{"","HTTP_OPERATION","URI_ENCODE","http://39.106.55.121/123/zhongwen/中文/zhongwen"},4,200},{{"","HTTP_OPERATION","CLIENT_CREAT","0","http://www.sswwdd.top"},5,200},{{"","HTTP_OPERATION","CLIENT_CFG","0","0","0","0","0"},8,200},{{"","HTTP_OPERATION","CLIENT_SET_CUSTOM_HEADER","0"},4,200},{{"","HTTP_OPERATION","CLIENT_IS_BUSY","0"},4,200},{{"","HTTP_OPERATION","CLIENT_REQUEST","0","test_content","12","1","http://www.sswwdd.top/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_FREE_SPECIFIC_HEADER","0"},4,200},{{"","HTTP_OPERATION","CLIENT_TERMINATE","0"},4,200},{{"","HTTP_OPERATION","CLIENT_REQUEST","0","test_content","12","2","http://www.sswwdd.top/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_GET_RESPONSE_CODE","0"},4,200},{{"","HTTP_OPERATION","CLIENT_PARSE_HEADER","Content-Type"},4,200},{{"","HTTP_OPERATION","CLIENT_FREE_DATA","0"},4,200},{{"","HTTP_OPERATION","CLIENT_DELETE","0"},4,200},\
{{"","HTTP_OPERATION","CLIENT_CREAT","1","http://www.sswwdd.top"},5,200},{{"","HTTP_OPERATION","CLIENT_CFG","1","0","0","0","0"},8,200},{{"","HTTP_OPERATION","CLIENT_SET_SPECIFIC_HEADER","1"},4,200},{{"","HTTP_OPERATION","CLIENT_IS_BUSY","1"},4,200},{{"","HTTP_OPERATION","CLIENT_REQUEST","1","test_content","12","1","http://www.sswwdd.top/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_FREE_SPECIFIC_HEADER","1"},4,200},{{"","HTTP_OPERATION","CLIENT_TERMINATE","1"},4,200},{{"","HTTP_OPERATION","CLIENT_REQUEST","1","test_content","12","3","http://www.sswwdd.top/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_GET_RESPONSE_CODE","1"},4,200},{{"","HTTP_OPERATION","CLIENT_PARSE_HEADER","Content-Type"},4,200},{{"","HTTP_OPERATION","CLIENT_FREE_DATA","1"},4,200},{{"","HTTP_OPERATION","CLIENT_DELETE","1"},4,200},\
{{"","HTTP_OPERATION","CLIENT_CREAT","2","http://www.sswwdd.top"},5,200},{{"","HTTP_OPERATION","CLIENT_CFG","2","0","0","0","1"},8,200},{{"","HTTP_OPERATION","CLIENT_SET_SPECIFIC_HEADER","2"},4,200},{{"","HTTP_OPERATION","CLIENT_IS_BUSY","2"},4,200},{{"","HTTP_OPERATION","CLIENT_REQUEST","2","test_content","12","1","http://www.sswwdd.top/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_FREE_SPECIFIC_HEADER","2"},4,200},{{"","HTTP_OPERATION","CLIENT_TERMINATE","2"},4,200},{{"","HTTP_OPERATION","CLIENT_REQUEST","2","test_content","12","4","http://www.sswwdd.top/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_GET_RESPONSE_CODE","2"},4,200},{{"","HTTP_OPERATION","CLIENT_PARSE_HEADER","Content-Type"},4,200},{{"","HTTP_OPERATION","CLIENT_FREE_DATA","2"},4,200},{{"","HTTP_OPERATION","CLIENT_DELETE","2"},4,200},\
{{"","HTTP_OPERATION","CLIENT_CREAT","3","http://www.sswwdd.top"},5,200},{{"","HTTP_OPERATION","CLIENT_CFG","3","0","0","0","2"},8,200},{{"","HTTP_OPERATION","CLIENT_SET_SPECIFIC_HEADER","3"},4,200},{{"","HTTP_OPERATION","CLIENT_IS_BUSY","3"},4,200},{{"","HTTP_OPERATION","CLIENT_REQUEST","3","test_content","12","1","http://www.sswwdd.top/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_FREE_SPECIFIC_HEADER","3"},4,200},{{"","HTTP_OPERATION","CLIENT_TERMINATE","3"},4,200},{{"","HTTP_OPERATION","CLIENT_REQUEST","3","test_content","12","5","http://www.sswwdd.top/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_GET_RESPONSE_CODE","3"},4,200},{{"","HTTP_OPERATION","CLIENT_PARSE_HEADER","Content-Type"},4,200},{{"","HTTP_OPERATION","CLIENT_FREE_DATA","3"},4,200},{{"","HTTP_OPERATION","CLIENT_DELETE","3"},4,200},\
/*ASYNC REQUEST*/
{{"","HTTP_OPERATION","CLIENT_CREAT","1","http://www.sswwdd.top"},5,200},{{"","HTTP_OPERATION","CLIENT_CFG","1","0","0","0","0"},8,200},{{"","HTTP_OPERATION","CLIENT_SET_SPECIFIC_HEADER","1"},4,200},{{"","HTTP_OPERATION","CLIENT_IS_BUSY","1"},4,200},{{"","HTTP_OPERATION","ASYNC_START","1","test_content","12","1","http://www.sswwdd.top/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_FREE_SPECIFIC_HEADER","1"},4,200},{{"","HTTP_OPERATION","CLIENT_GET_RESPONSE_CODE","1"},4,200},{{"","HTTP_OPERATION","CLIENT_PARSE_HEADER","Content-Type"},4,200},{{"","HTTP_OPERATION","CLIENT_FREE_DATA","1"},4,200},{{"","HTTP_OPERATION","CLIENT_TERMINATE","1"},4,200},{{"","HTTP_OPERATION","CLIENT_DELETE","1"},4,200},\
/*END*/
{{"","HTTP_OPERATION","ADD_CER","0"},4,200},{{"","HTTP_OPERATION","CLIENT_CREAT","0","https://www.sswwdd.top:443"},5,200},{{"","HTTP_OPERATION","CLIENT_CFG","0","1","0","1","2"},8,200},{{"","HTTP_OPERATION","CLIENT_SET_SPECIFIC_HEADER","0"},4,200},{{"","HTTP_OPERATION","CLIENT_IS_BUSY","0"},4,200},{{"","HTTP_OPERATION","CLIENT_REQUEST","0","test_content","12","1","https://www.sswwdd.top:443/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_FREE_SPECIFIC_HEADER","0"},4,200},{{"","HTTP_OPERATION","CLIENT_TERMINATE","0"},4,200},{{"","HTTP_OPERATION","CLIENT_REQUEST","0","test_content","12","1","https://www.sswwdd.top:443/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_GET_RESPONSE_CODE","0"},4,200},{{"","HTTP_OPERATION","CLIENT_PARSE_HEADER","Content-Type"},4,200},{{"","HTTP_OPERATION","CLIENT_FREE_DATA","0"},4,200},{{"","HTTP_OPERATION","CLIENT_TERMINATE","0"},4,200},{{"","HTTP_OPERATION","CLIENT_DELETE","0"},4,200},\
{{"","HTTP_OPERATION","ADD_CER","1"},4,200},{{"","HTTP_OPERATION","CLIENT_CREAT","1","https://www.sswwdd.top:443"},5,200},{{"","HTTP_OPERATION","CLIENT_CFG","1","1","1","1","2"},8,200},{{"","HTTP_OPERATION","CLIENT_SET_SPECIFIC_HEADER","1"},4,200},{{"","HTTP_OPERATION","CLIENT_IS_BUSY","1"},4,200},{{"","HTTP_OPERATION","CLIENT_REQUEST","1","test_content","12","2","https://www.sswwdd.top:443/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_FREE_SPECIFIC_HEADER","1"},4,200},{{"","HTTP_OPERATION","CLIENT_TERMINATE","1"},4,200},{{"","HTTP_OPERATION","CLIENT_REQUEST","1","test_content","12","1","https://www.sswwdd.top:443/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_GET_RESPONSE_CODE","1"},4,200},{{"","HTTP_OPERATION","CLIENT_PARSE_HEADER","Content-Type"},4,200},{{"","HTTP_OPERATION","CLIENT_FREE_DATA","1"},4,200},{{"","HTTP_OPERATION","CLIENT_TERMINATE","1"},4,200},{{"","HTTP_OPERATION","CLIENT_DELETE","1"},4,200},\
{{"","HTTP_OPERATION","ADD_CER","2"},4,200},{{"","HTTP_OPERATION","CLIENT_CREAT","2","https://www.sswwdd.top:443"},5,200},{{"","HTTP_OPERATION","CLIENT_CFG","2","1","2","1","2"},8,200},{{"","HTTP_OPERATION","CLIENT_SET_SPECIFIC_HEADER","2"},4,200},{{"","HTTP_OPERATION","CLIENT_IS_BUSY","2"},4,200},{{"","HTTP_OPERATION","CLIENT_REQUEST","2","test_content","12","3","https://www.sswwdd.top:443/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_FREE_SPECIFIC_HEADER","2"},4,200},{{"","HTTP_OPERATION","CLIENT_TERMINATE","2"},4,200},{{"","HTTP_OPERATION","CLIENT_REQUEST","2","test_content","12","1","https://www.sswwdd.top:443/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_GET_RESPONSE_CODE","2"},4,200},{{"","HTTP_OPERATION","CLIENT_PARSE_HEADER","Content-Type"},4,200},{{"","HTTP_OPERATION","CLIENT_FREE_DATA","2"},4,200},{{"","HTTP_OPERATION","CLIENT_TERMINATE","2"},4,200},{{"","HTTP_OPERATION","CLIENT_DELETE","2"},4,200},\
{{"","HTTP_OPERATION","ADD_CER","3"},4,200},{{"","HTTP_OPERATION","CLIENT_CREAT","3","https://www.sswwdd.top:443"},5,200},{{"","HTTP_OPERATION","CLIENT_CFG","3","1","3","1","2"},8,200},{{"","HTTP_OPERATION","CLIENT_SET_SPECIFIC_HEADER","3"},4,200},{{"","HTTP_OPERATION","CLIENT_IS_BUSY","3"},4,200},{{"","HTTP_OPERATION","CLIENT_REQUEST","3","test_content","12","4","https://www.sswwdd.top:443/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_FREE_SPECIFIC_HEADER","3"},4,200},{{"","HTTP_OPERATION","CLIENT_TERMINATE","3"},4,200},{{"","HTTP_OPERATION","CLIENT_REQUEST","3","test_content","12","1","https://www.sswwdd.top:443/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_GET_RESPONSE_CODE","3"},4,200},{{"","HTTP_OPERATION","CLIENT_PARSE_HEADER","Content-Type"},4,200},{{"","HTTP_OPERATION","CLIENT_FREE_DATA","3"},4,200},{{"","HTTP_OPERATION","CLIENT_TERMINATE","3"},4,200},{{"","HTTP_OPERATION","CLIENT_DELETE","3"},4,200},\
{{"","HTTP_OPERATION","ADD_CER","4"},4,200},{{"","HTTP_OPERATION","CLIENT_CREAT","3","https://www.sswwdd.top:443"},5,200},{{"","HTTP_OPERATION","CLIENT_CFG","3","1","4","1","2"},8,200},{{"","HTTP_OPERATION","CLIENT_SET_SPECIFIC_HEADER","3"},4,200},{{"","HTTP_OPERATION","CLIENT_IS_BUSY","3"},4,200},{{"","HTTP_OPERATION","CLIENT_REQUEST","3","test_content","12","5","https://www.sswwdd.top:443/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_FREE_SPECIFIC_HEADER","3"},4,200},{{"","HTTP_OPERATION","CLIENT_TERMINATE","3"},4,200},{{"","HTTP_OPERATION","CLIENT_REQUEST","3","test_content","12","1","https://www.sswwdd.top:443/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_GET_RESPONSE_CODE","3"},4,200},{{"","HTTP_OPERATION","CLIENT_PARSE_HEADER","Content-Type"},4,200},{{"","HTTP_OPERATION","CLIENT_FREE_DATA","3"},4,200},{{"","HTTP_OPERATION","CLIENT_TERMINATE","3"},4,200},{{"","HTTP_OPERATION","CLIENT_DELETE","3"},4,200},\
{{"","HTTP_OPERATION","ADD_CER","5"},4,200},{{"","HTTP_OPERATION","CLIENT_CREAT","3","https://www.sswwdd.top:443"},5,200},{{"","HTTP_OPERATION","CLIENT_CFG","3","1","5","1","2"},8,200},{{"","HTTP_OPERATION","CLIENT_SET_SPECIFIC_HEADER","3"},4,200},{{"","HTTP_OPERATION","CLIENT_IS_BUSY","3"},4,200},{{"","HTTP_OPERATION","CLIENT_REQUEST","3","test_content","12","1","https://www.sswwdd.top:443/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_FREE_SPECIFIC_HEADER","3"},4,200},{{"","HTTP_OPERATION","CLIENT_TERMINATE","3"},4,200},{{"","HTTP_OPERATION","CLIENT_REQUEST","3","test_content","12","1","https://www.sswwdd.top:443/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_GET_RESPONSE_CODE","3"},4,200},{{"","HTTP_OPERATION","CLIENT_PARSE_HEADER","Content-Type"},4,200},{{"","HTTP_OPERATION","CLIENT_FREE_DATA","3"},4,200},{{"","HTTP_OPERATION","CLIENT_TERMINATE","3"},4,200},{{"","HTTP_OPERATION","CLIENT_DELETE","3"},4,200},\
/*ASYNC REQUEST*/
{{"","HTTP_OPERATION","ADD_CER","5"},4,200},{{"","HTTP_OPERATION","CLIENT_CREAT","3","https://www.sswwdd.top:443"},5,200},{{"","HTTP_OPERATION","CLIENT_CFG","3","1","5","1","2"},8,200},{{"","HTTP_OPERATION","CLIENT_SET_SPECIFIC_HEADER","3"},4,200},{{"","HTTP_OPERATION","CLIENT_IS_BUSY","3"},4,200},{{"","HTTP_OPERATION","ASYNC_START","3","test_content","12","2","https://www.sswwdd.top:443/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_GET_RESPONSE_CODE","3"},4,200},{{"","HTTP_OPERATION","CLIENT_PARSE_HEADER","Content-Type"},4,200},{{"","HTTP_OPERATION","CLIENT_FREE_DATA","3"},4,200},{{"","HTTP_OPERATION","CLIENT_TERMINATE","3"},4,200},{{"","HTTP_OPERATION","CLIENT_DELETE","3"},4,200},\
{{"","HTTP_OPERATION","ADD_CER","5"},4,200},{{"","HTTP_OPERATION","CLIENT_CREAT","3","https://www.sswwdd.top:443"},5,200},{{"","HTTP_OPERATION","CLIENT_CFG","3","1","5","1","2"},8,200},{{"","HTTP_OPERATION","CLIENT_SET_SPECIFIC_HEADER","3"},4,200},{{"","HTTP_OPERATION","CLIENT_IS_BUSY","3"},4,200},{{"","HTTP_OPERATION","ASYNC_START","3","test_content","12","1","https://www.sswwdd.top:443/anything"},8,200},{{"","HTTP_OPERATION","CLIENT_GET_RESPONSE_CODE","3"},4,200},{{"","HTTP_OPERATION","CLIENT_PARSE_HEADER","Content-Type"},4,200},{{"","HTTP_OPERATION","CLIENT_FREE_DATA","3"},4,200},{{"","HTTP_OPERATION","CLIENT_TERMINATE","3"},4,200},{{"","HTTP_OPERATION","CLIENT_DELETE","3"},4,200},\
/*END*/
{{"end"},1,0}},
};

test_suite_cmd_t test_iomux_cmd = {
    .name = "iomux",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_iomux_operation,
    .suite_cmd = {{{"","IOMUX_OPERATION","SET_GET_FUNC","49","1"},5,50},{{"","IOMUX_OPERATION","SET_GET_FUNC","49","2"},5,50},{{"","IOMUX_OPERATION","SET_GET_FUNC","49","3"},5,50},\
{{"","IOMUX_OPERATION","SET_PIN_CMD","49","0","0"},6,50},{{"","IOMUX_OPERATION","SET_PIN_CMD","49","0","5"},6,50},{{"","IOMUX_OPERATION","SET_PIN_CMD","49","0","1"},6,50},{{"","IOMUX_OPERATION","SET_PIN_CMD","49","0","2"},6,50},{{"","IOMUX_OPERATION","SET_PIN_CMD","49","0","3"},6,50},{{"","IOMUX_OPERATION","SET_PIN_CMD","49","0","4"},6,50},\
{{"","IOMUX_OPERATION","SET_PIN_CMD","49","1","0"},6,50},{{"","IOMUX_OPERATION","SET_PIN_CMD","49","1","1"},6,50},{{"","IOMUX_OPERATION","SET_PIN_CMD","49","1","2"},6,50},{{"","IOMUX_OPERATION","SET_PIN_CMD","49","1","3"},6,50},\
{{"","IOMUX_OPERATION","SET_PIN_CMD","49","2","0"},6,50},{{"","IOMUX_OPERATION","SET_PIN_CMD","49","0","1"},6,50},{{"","IOMUX_OPERATION","SET_PIN_CMD","49","0","2"},6,50},{{"","IOMUX_OPERATION","SET_PIN_CMD","49","0","3"},6,50},{{"","IOMUX_OPERATION","SET_PIN_CMD","49","0","4"},6,50},\
{{"","IOMUX_OPERATION","SET_PIN_CMD","49","3","0"},6,50},{{"","IOMUX_OPERATION","SET_PIN_CMD","49","3","1"},6,50},{{"","IOMUX_OPERATION","SET_PIN_CMD","49","3","2"},6,50},{{"","IOMUX_OPERATION","SET_PIN_CMD","49","3","3"},6,50},{{"","IOMUX_OPERATION","SET_PIN_CMD","49","3","4"},6,50},\
{{"end"},1,0}},
};

test_suite_cmd_t test_lbs_cmd = {
    .name = "lbs",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_lbs_operation,
    .suite_cmd = {{{"","LBS_OPERATION","INIT","40","B7rKhYWAJ1","5","null","0","1","0"},10,50},{{"","LBS_OPERATION","GET_ATTR","40"},4,50},{{"","LBS_OPERATION","GET_LOC","location"},4,800},{{"","LBS_OPERATION","DEINIT"},3,50},\
{{"","LBS_OPERATION","INIT","40","B7rKhYWAJ1","5","null","0","0","0"},10,50},{{"","LBS_OPERATION","GET_ATTR","40"},4,50},{{"","LBS_OPERATION","GET_LOC","location"},4,800},{{"","LBS_OPERATION","DEINIT"},3,50},\
{{"","LBS_OPERATION","INIT","11","d577a4352cb386a00fda4e7f4e05369f","5","0","null","0","0"},10,50},{{"","LBS_OPERATION","GET_ATTR","11"},4,50},{{"","LBS_OPERATION","GET_LOC","location"},4,800},{{"","LBS_OPERATION","DEINIT"},3,50},\
{{"","LBS_OPERATION","INIT","10","bb5331d16f46a757c2b7506109a87745","5","0","null","0","0"},10,50},{{"","LBS_OPERATION","GET_ATTR","10"},4,50},{{"","LBS_OPERATION","GET_LOC","location"},4,800},{{"","LBS_OPERATION","DEINIT"},3,50},\
{{"","LBS_OPERATION","INIT","10","c72f62a11254fad52fc5890b3eacc224","5","1","959e237c3409311ae3ebf27edc4866a0","0","0"},10,50},{{"","LBS_OPERATION","GET_ATTR","10"},4,50},{{"","LBS_OPERATION","GET_LOC","location"},4,800},{{"","LBS_OPERATION","DEINIT"},3,50},\
{{"","LBS_OPERATION","INIT","10","bb5331d16f46a757c2b7506109a87745","5","1","959e237c3409311ae3ebf27edc4866a0","1","0"},10,50},{{"","LBS_OPERATION","GET_ATTR","10"},4,50},{{"","LBS_OPERATION","GET_LOC","location"},4,800},{{"","LBS_OPERATION","DEINIT"},3,50},\
{{"","LBS_OPERATION","INIT","11","1804ca2fe7f519870be262fea7d88272","5","1","9406738e068c1297924a4d7b14d05e17","0","0"},10,50},{{"","LBS_OPERATION","GET_ATTR","11"},4,50},{{"","LBS_OPERATION","GET_LOC","location"},4,800},{{"","LBS_OPERATION","DEINIT"},3,50},\
{{"","LBS_OPERATION","INIT","11","d577a4352cb386a00fda4e7f4e05369f","5","0","null","0","1"},10,50},{{"","LBS_OPERATION","GET_ATTR","11"},4,50},{{"","LBS_OPERATION","GET_LOC","location"},4,800},{{"","LBS_OPERATION","DEINIT"},3,50},\
{{"","LBS_OPERATION","INIT","11","1804ca2fe7f519870be262fea7d88272","5","1","9406738e068c1297924a4d7b14d05e17","1","0"},10,50},{{"","LBS_OPERATION","GET_ATTR","11"},4,50},{{"","LBS_OPERATION","GET_LOC","location"},4,800},{{"","LBS_OPERATION","DEINIT"},3,50},\
{{"end"},1,0}},
};


test_suite_cmd_t test_mem_cmd = {
    .name = "mem",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_mem_operation,
    .suite_cmd = {{{"","MEM_OPERATION","LLOC_FREE"},3,200},{{"end"},1,0}},
};

test_suite_cmd_t test_modem_cmd = {
    .name = "modem",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_modem_operation,
    .suite_cmd = {{{"","MODEM_OPERATION","CGMM"},3,200},{{"","MODEM_OPERATION","CGMI"},3,200},{{"","MODEM_OPERATION","COPS"},3,200},{{"","MODEM_OPERATION","CSQ"},3,200},{{"","MODEM_OPERATION","RADIO_INFO"},3,200},{{"","MODEM_OPERATION","CELL_INFO"},3,200},{{"","MODEM_OPERATION","SET_GET_CFUN","0"},4,1000},\
{{"","MODEM_OPERATION","SET_GET_CFUN","1"},4,1000},{{"","MODEM_OPERATION","SET_GET_EDRX"},3,200},{{"","MODEM_OPERATION","SET_GET_PSM"},3,200},{{"","MODEM_OPERATION","GET_CEREG"},3,200},{{"","MODEM_OPERATION","GET_CSCON"},3,200},{{"","MODEM_OPERATION","ACT_DEACT_PDP","1"},4,200},\
{{"","MODEM_OPERATION","GET_PDP_STATE","1"},4,200},{{"","MODEM_OPERATION","GET_CPIN"},3,200},{{"","MODEM_OPERATION","CGMR"},3,200},\
{{"end"},1,0}},
};

test_suite_cmd_t test_modem_info_cmd = {
    .name = "modem_info",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_modem_info_operation,
    .suite_cmd = {{{"","MODEM_INFO_OPERATION","INFO_RADIO"},3,200},{{"","MODEM_INFO_OPERATION","INFO_CELL"},3,200},\
{{"end"},1,0}},
};

test_suite_cmd_t test_mqtt_cmd = {
    .name = "mqtt",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_mqtt_operation,
    .suite_cmd = {{{"","MQTT_OPERATION","0","0","0","keepalive","60"},7,200},{{"","MQTT_OPERATION","0","0","1"},5,200},{{"","MQTT_OPERATION","0","0","2"},5,200},{{"","MQTT_OPERATION","0","0","3"},5,200},{{"","MQTT_OPERATION","0","0","5"},5,200},{{"","MQTT_OPERATION","0","0","4"},5,200},{{"","MQTT_OPERATION","0","0","8"},5,200},{{"","MQTT_OPERATION","0","0","9"},5,200},\
{{"","MQTT_OPERATION","1","1","0","keepalive","60"},7,200},{{"","MQTT_OPERATION","1","1","1"},5,200},{{"","MQTT_OPERATION","1","1","2"},5,200},{{"","MQTT_OPERATION","1","1","3"},5,200},{{"","MQTT_OPERATION","1","1","5"},5,200},{{"","MQTT_OPERATION","1","1","4"},5,200},{{"","MQTT_OPERATION","1","1","8"},5,200},{{"","MQTT_OPERATION","1","1","9"},5,200},\
{{"","MQTT_OPERATION","0","2","0","keepalive","60"},7,200},{{"","MQTT_OPERATION","0","2","1"},5,200},{{"","MQTT_OPERATION","0","2","2"},5,200},{{"","MQTT_OPERATION","0","2","3"},5,200},{{"","MQTT_OPERATION","0","2","5"},5,200},{{"","MQTT_OPERATION","0","2","4"},5,200},\
{{"","MQTT_OPERATION","0","3","0","keepalive","60"},7,200},{{"","MQTT_OPERATION","0","3","1"},5,200},{{"","MQTT_OPERATION","0","3","2"},5,200},{{"","MQTT_OPERATION","0","3","3"},5,200},{{"","MQTT_OPERATION","0","3","5"},5,200},{{"","MQTT_OPERATION","0","3","4"},5,200},{{"","MQTT_OPERATION","0","3","8"},5,200},{{"","MQTT_OPERATION","0","3","9"},5,200},\
{{"","MQTT_OPERATION","0","4","0","keepalive","60"},7,200},{{"","MQTT_OPERATION","0","4","1"},5,200},{{"","MQTT_OPERATION","0","4","2"},5,200},{{"","MQTT_OPERATION","0","4","3"},5,200},{{"","MQTT_OPERATION","0","4","5"},5,200},/*{{"","MQTT_OPERATION","0","4","4"},5,200},*/\
/*{{"","MQTT_OPERATION","0","0","6"},5,200},*/{{"","MQTT_OPERATION","0","0","7"},5,200},{{"","MQTT_OPERATION","1","1","6"},5,200},{{"","MQTT_OPERATION","1","1","7"},5,200},{{"","MQTT_OPERATION","0","2","6"},5,200},{{"","MQTT_OPERATION","0","2","7"},5,200},\
{{"","MQTT_OPERATION","0","3","6"},5,200},{{"","MQTT_OPERATION","0","3","7"},5,200},{{"","MQTT_OPERATION","0","4","6"},5,200},{{"","MQTT_OPERATION","0","4","7"},5,200},\
{{"end"},1,0}},
};


test_suite_cmd_t test_ntp_cmd = {
    .name = "ntp",
    .pre_con = "set sys time",
    .pre_exec = {{{"","RTC_OPERATION","SET_SYS_TIME","1659951891"},4,200},{{"","VIRT_AT_OPERATION","INIT"},3,200},{{"","VIRT_AT_OPERATION","SEND","AT+CCLK?"},4,200},{{"end"},1,0}},
    .pre_func = cm_test_rtc_operation,
    .suite_func = cm_test_ntp_operation,
    .suite_cmd = {{{"","NTP_OPERATION","CFG","ntp.ntsc.ac.cn","123","0","1"},7,200},{{"","NTP_OPERATION","SYNC"},3,600},{{"","VIRT_AT_OPERATION","SEND","AT+CCLK?"},4,200},\
{{"","RTC_OPERATION","SET_SYS_TIME","1659951891"},4,200},{{"","NTP_OPERATION","CFG","ntp.ntsc.ac.cn","123","0","0"},7,200},{{"","VIRT_AT_OPERATION","SEND","AT+CCLK?"},4,200},{{"","NTP_OPERATION","SYNC"},3,600},{{"","VIRT_AT_OPERATION","SEND","AT+CCLK?"},4,200},\
{{"","NTP_OPERATION","CFG","ntp.ntsc.ac.cn","123","0","1"},7,200},{{"","NTP_OPERATION","SYNC"},3,600},{{"","VIRT_AT_OPERATION","SEND","AT+CCLK?"},4,200},{{"","VIRT_AT_OPERATION","DEINIT"},3,100},\
{{"","RTC_OPERATION","GET_TIME_OF_DAY"},3,200},\
{{"end"},1,0}},
};


test_suite_cmd_t test_os_cmd = {
    .name = "os",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_os_operation,
    .suite_cmd = {{{"","OS_OPERATION","TICK"},3,200},{{"","OS_OPERATION","KERNEL","LOCK"},4,0},{{"","OS_OPERATION","KERNEL","UNLOCK"},4,10},{{"","OS_OPERATION","THREAD","CREAT"},4,800},{{"","OS_OPERATION","THREAD","STATE"},4,200},{{"","OS_OPERATION","THREAD","STACK_SIZE"},4,200},{{"","OS_OPERATION","THREAD","SET_GET_PRIORITY","4"},5,200},{{"","OS_OPERATION","THREAD","SUSPEND"},4,800},\
{{"","OS_OPERATION","THREAD","YIELD"},4,800},{{"","OS_OPERATION","THREAD","RESUME"},4,200},{{"","OS_OPERATION","THREAD","GET_COUNT"},4,200},{{"","OS_OPERATION","THREAD","TERMINATE"},4,200},{{"","OS_OPERATION","DELAY","1000"},4,1100},{{"","OS_OPERATION","TIMER","NEW"},4,200},{{"","OS_OPERATION","TIMER","GET_NAME"},4,200},\
{{"","OS_OPERATION","TIMER","START","400"},5,1000},{{"","OS_OPERATION","TIMER","STATE"},4,500},{{"","OS_OPERATION","TIMER","STATE"},4,200},{{"","OS_OPERATION","TIMER","STOP"},4,800},{{"","OS_OPERATION","TIMER","STATE"},4,200},{{"","OS_OPERATION","TIMER","STATE"},4,200},{{"","OS_OPERATION","TIMER","DELETE"},4,200},\
{{"","OS_OPERATION","EVENT","NEW"},4,200},{{"","OS_OPERATION","EVENT","SET","15"},5,200},{{"","OS_OPERATION","EVENT","WAIT","1"},5,200},{{"","OS_OPERATION","EVENT","WAIT","2"},5,200},{{"","OS_OPERATION","EVENT","WAIT","4"},5,200},{{"","OS_OPERATION","EVENT","WAIT","8"},5,200},{{"","OS_OPERATION","EVENT","GET"},4,200},\
{{"","OS_OPERATION","EVENT","CLEAR","1"},5,200},{{"","OS_OPERATION","EVENT","DELETE"},4,200},{{"","OS_OPERATION","MUTEX","NEW"},4,200},{{"","OS_OPERATION","MUTEX","ACQUIRE"},4,600},{{"","OS_OPERATION","MUTEX","OWNER"},4,200},{{"","OS_OPERATION","MUTEX","RELEASE"},4,600},{{"","OS_OPERATION","MUTEX","OWNER"},4,200},{{"","OS_OPERATION","MUTEX","DELETE"},4,200},\
{{"","OS_OPERATION","SEMAPHORE","NEW","10","3"},6,200},{{"","OS_OPERATION","SEMAPHORE","GETCOUNT"},4,200},{{"","OS_OPERATION","SEMAPHORE","ACQUIRE"},4,200},{{"","OS_OPERATION","SEMAPHORE","ACQUIRE"},4,200},{{"","OS_OPERATION","SEMAPHORE","GETCOUNT"},4,200},{{"","OS_OPERATION","SEMAPHORE","RELEASE"},4,200},{{"","OS_OPERATION","SEMAPHORE","GETCOUNT"},4,200},\
{{"","OS_OPERATION","SEMAPHORE","DELETE"},4,200},{{"","OS_OPERATION","MESSAGE_QUEUE","NEW","13","50"},6,200},{{"","OS_OPERATION","MESSAGE_QUEUE","QUEUEPUT","123abc","12","1000"},7,600},{{"","OS_OPERATION","MESSAGE_QUEUE","QUEUEGET","10"},5,600},{{"","OS_OPERATION","MESSAGE_QUEUE","COUNT"},4,200},\
{{"","OS_OPERATION","MESSAGE_QUEUE","CAPACITY"},4,200},{{"","OS_OPERATION","MESSAGE_QUEUE","MSGSIZE"},4,200},{{"","OS_OPERATION","MESSAGE_QUEUE","SPACE"},4,200},{{"","OS_OPERATION","MESSAGE_QUEUE","RESET"},4,200},{{"","OS_OPERATION","MESSAGE_QUEUE","DELETE"},4,200},\
{{"end"},1,0}},
};

test_suite_cmd_t test_rtc_cmd = {
    .name = "rtc",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_rtc_operation,
    .suite_cmd = {{{"","RTC_OPERATION","SET_SYS_TIME","1659951891"},4,50},{{"","RTC_OPERATION","GET_CUR_TIME"},3,50},{{"","RTC_OPERATION","SET_TIME_ZONE","-12"},4,50},{{"","RTC_OPERATION","GET_TIME_ZONE"},3,50},\
    {{"","RTC_OPERATION","SET_SYS_TIME","1859951891"},4,50},{{"","RTC_OPERATION","GET_CUR_TIME"},3,50},{{"","RTC_OPERATION","SET_GET_TIME_ZONE"},3,50},\
{{"end"},1,0}},
};

test_suite_cmd_t test_sd_cmd = {
    .name = "sd",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_sd_operation,
    .suite_cmd = {{{"","SD_OPERATION","ISFORMAT","D"},4,200},/*{{"","SD_OPERATION","FORMAT","D"},4,200},*/{{"","SD_OPERATION","OPEN","D","\\TEST1.txt","wc"},6,200},{{"","SD_OPERATION","WRITE","1234567890abcdwf0123456789zyxlkjhgfdsapoiuytrewq.,","51"},5,200},/*{{"","SD_OPERATION","SEEK","0","SD_SEEK_SET"},5,200},{{"","SD_OPERATION","READ","35"},4,200},{{"","SD_OPERATION","SEEK","2","SD_SEEK_CUR"},5,200},{{"","SD_OPERATION","READ","3"},4,200},{{"","SD_OPERATION","SEEK","0","SD_SEEK_END"},5,200},{{"","SD_OPERATION","READ","5"},4,200},*/{{"","SD_OPERATION","CLOSE"},3,200},\
{{"","SD_OPERATION","OPEN","D","\\TEST1.txt","ac"},6,200},{{"","SD_OPERATION","WRITE","1234567890abcdwf0123456789zyxlkjhgfdsapoiuytrewq.,","51"},5,200},{{"","SD_OPERATION","SEEK","0","SD_SEEK_SET"},5,200},/*{{"","SD_OPERATION","READ","35"},4,200},*/{{"","SD_OPERATION","CLOSE"},3,200},\
{{"","SD_OPERATION","OPEN","D","\\TEST1.txt","r"},6,200},{{"","SD_OPERATION","READ","100"},4,200},{{"","SD_OPERATION","CLOSE"},3,200},\
{{"","SD_OPERATION","OPEN","D","\\TEST1.txt","+"},6,200},{{"","SD_OPERATION","WRITE","1234567890abcdwf0123456789zyxlkjhgfdsapoiuytrewq.,","51"},5,200},{{"","SD_OPERATION","SEEK","0","SD_SEEK_SET"},5,200},{{"","SD_OPERATION","READ","100"},4,200},{{"","SD_OPERATION","CLOSE"},3,200},\
{{"","SD_OPERATION","EXIST","D","\\TEST1.txt"},5,200},{{"","SD_OPERATION","FILESIZE","D","\\TEST1.txt"},5,200},{{"","SD_OPERATION","MOVE","D","\\TEST1.txt","D","\\TEST5.txt"},5,200},{{"","SD_OPERATION","EXIST","D","\\TEST5.txt"},5,200},{{"","SD_OPERATION","MKDIR","D","\\TEMP"},5,200},{{"","SD_OPERATION","MKDIR","D","\\TEMP\\1"},5,200},{{"","SD_OPERATION","SET_CURDIR","D","\\TEMP"},5,200},{{"","SD_OPERATION","GET_CURDIR"},3,200},{{"","SD_OPERATION","RMDIR","D","\\TEMP\\1"},5,200},{{"","SD_OPERATION","OPEN","D","TEST1.txt","ac"},6,200},{{"","SD_OPERATION","CLOSE"},3,200},\
{{"","SD_OPERATION","OPEN","D","TEST2.txt","ac"},6,200},{{"","SD_OPERATION","CLOSE"},3,200},{{"","SD_OPERATION","DELETE","D","TEST2.txt"},5,200},{{"","SD_OPERATION","GET_INFO","D"},5,200},\
{{"end"},1,0}},
};

test_suite_cmd_t test_sim_cmd = {
    .name = "sim",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_sim_operation,
    .suite_cmd = {{{"","SIM_OPERATION","IMSI"},3,50},{{"end"},1,0}},
};

test_suite_cmd_t test_ssl_cmd = {
    .name = "ssl",
    .pre_con = "asocket_connect",
    .pre_exec = {{{"","ASOCKET_OPERATION","ASOCKET_OPEN_CONNECT","TCPIPV6","9999"},5,200},{{"end"},1,0}},
    .pre_func = cm_test_asocket_operation,//cm_test_http_operation,
    .suite_func = cm_test_ssl_operation,
    .suite_cmd = {{{"","SSL_OPERATION","SETOPT","0","0","2"},6,50},{{"","SSL_OPERATION","SETOPT","0","1","20"},6,50},{{"","SSL_OPERATION","SETOPT","0","2","2"},6,50},{{"","SSL_OPERATION","SETOPT","0","3","2"},6,50},{{"","SSL_OPERATION","SETOPT","0","4","2"},6,50},\
{{"suite","SSL_OPERATION","CONNECT","0","20","6000"},6,200},{{"","SSL_OPERATION","WRITE","02468013579"},4,200},{{"","SSL_OPERATION","READ"},3,200},{{"","SSL_OPERATION","CHECK_PENDING"},3,200},{{"","SSL_OPERATION","BYTES_AVAIL"},3,200},{{"","SSL_OPERATION","CLOSE"},3,200},\
{{"end"},1,0}},
};

test_suite_cmd_t test_sys_cmd = {
    .name = "sys",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_sys_operation,
    .suite_cmd = {{{"","SYS_OPERATION","SN"},3,50},{{"","SYS_OPERATION","IMEI"},3,50},{{"","SYS_OPERATION","CM_VER"},3,50},{{"","SYS_OPERATION","LOG_PRINT"},3,50},{{"","SYS_OPERATION","DEMO_PRINT"},3,50},\
{{"end"},1,0}},
};

test_suite_cmd_t test_tts_cmd = {
    .name = "tts",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_tts_operation,
    .suite_cmd = {
{{"","TTS_OPERATION","INIT","0","0","2","0","0","0","2"},10,50},{{"","TTS_OPERATION","STATE"},3,200},{{"","TTS_OPERATION","PLAY","baidu百度tts"},4,800},{{"","TTS_OPERATION","STATE"},3,50},{{"","TTS_OPERATION","STOP"},3,50},{{"","TTS_OPERATION","DEINIT"},3,50},\
{{"","TTS_OPERATION","INIT","1","1","2","0","1","1","2"},10,50},{{"","TTS_OPERATION","STATE"},3,200},{{"","TTS_OPERATION","PLAY","baidu百度tts"},4,800},{{"","TTS_OPERATION","STATE"},3,50},{{"","TTS_OPERATION","STOP"},3,50},{{"","TTS_OPERATION","DEINIT"},3,50},\
{{"","TTS_OPERATION","INIT","2","2","2","0","2","2","2"},10,50},{{"","TTS_OPERATION","PLAY","baidu百度tts"},4,200},{{"","TTS_OPERATION","STATE"},3,200},{{"","TTS_OPERATION","STOP"},3,50},{{"","TTS_OPERATION","DEINIT"},3,50},\
{{"","TTS_OPERATION","INIT","3","3","2","0","3","3","2"},10,50},{{"","TTS_OPERATION","PLAY","baidu百度tts"},4,200},{{"","TTS_OPERATION","STATE"},3,200},{{"","TTS_OPERATION","STOP"},3,50},{{"","TTS_OPERATION","DEINIT"},3,50},\
{{"","TTS_OPERATION","INIT","4","4","2","0","4","4","2"},10,50},{{"","TTS_OPERATION","PLAY","baidu百度tts"},4,200},{{"","TTS_OPERATION","STATE"},3,200},{{"","TTS_OPERATION","STOP"},3,50},{{"","TTS_OPERATION","DEINIT"},3,50},\
{{"","TTS_OPERATION","INIT","5","5","2","0","5","0","2"},10,50},{{"","TTS_OPERATION","PLAY","baidu百度tts"},4,200},{{"","TTS_OPERATION","STATE"},3,200},{{"","TTS_OPERATION","STOP"},3,50},{{"","TTS_OPERATION","DEINIT"},3,50},\
{{"","TTS_OPERATION","INIT","6","6","2","0","6","1","2"},10,50},{{"","TTS_OPERATION","PLAY","baidu百度tts"},4,200},{{"","TTS_OPERATION","STATE"},3,200},{{"","TTS_OPERATION","STOP"},3,50},{{"","TTS_OPERATION","DEINIT"},3,50},\
{{"","TTS_OPERATION","INIT","7","7","2","0","7","2","2"},10,50},{{"","TTS_OPERATION","PLAY","baidu百度tts"},4,200},{{"","TTS_OPERATION","STATE"},3,200},{{"","TTS_OPERATION","STOP"},3,50},{{"","TTS_OPERATION","DEINIT"},3,50},\
{{"","TTS_OPERATION","INIT","8","8","2","0","8","3","2"},10,50},{{"","TTS_OPERATION","PLAY","baidu百度tts"},4,200},{{"","TTS_OPERATION","STATE"},3,200},{{"","TTS_OPERATION","STOP"},3,50},{{"","TTS_OPERATION","DEINIT"},3,50},\
{{"","TTS_OPERATION","INIT","9","9","2","0","9","4","2"},10,50},{{"","TTS_OPERATION","PLAY","baidu百度tts"},4,200},{{"","TTS_OPERATION","STATE"},3,200},{{"","TTS_OPERATION","STOP"},3,50},{{"","TTS_OPERATION","DEINIT"},3,50},\
{{"","TTS_OPERATION","INIT","10","10","2","0","10","0","2"},10,50},{{"","TTS_OPERATION","PLAY","baidu百度tts"},4,200},{{"","TTS_OPERATION","STATE"},3,200},{{"","TTS_OPERATION","STOP"},3,50},{{"","TTS_OPERATION","DEINIT"},3,50},\
{{"","TTS_OPERATION","INIT","11","11","2","0","11","1","2"},10,50},{{"","TTS_OPERATION","PLAY","baidu百度tts"},4,200},{{"","TTS_OPERATION","STATE"},3,200},{{"","TTS_OPERATION","STOP"},3,50},{{"","TTS_OPERATION","DEINIT"},3,50},\
{{"","TTS_OPERATION","INIT","12","12","2","0","12","2","2"},10,50},{{"","TTS_OPERATION","PLAY","baidu百度tts"},4,200},{{"","TTS_OPERATION","STATE"},3,200},{{"","TTS_OPERATION","STOP"},3,50},{{"","TTS_OPERATION","DEINIT"},3,50},\
{{"","TTS_OPERATION","INIT","13","13","2","0","13","3","2"},10,50},{{"","TTS_OPERATION","PLAY","baidu百度tts"},4,200},{{"","TTS_OPERATION","STATE"},3,200},{{"","TTS_OPERATION","STOP"},3,50},{{"","TTS_OPERATION","DEINIT"},3,50},\
{{"","TTS_OPERATION","INIT","14","14","2","0","14","4","2"},10,50},{{"","TTS_OPERATION","PLAY","baidu百度tts"},4,200},{{"","TTS_OPERATION","STATE"},3,200},{{"","TTS_OPERATION","STOP"},3,50},{{"","TTS_OPERATION","DEINIT"},3,50},\
{{"","TTS_OPERATION","INIT","15","15","2","0","15","0","2"},10,50},{{"","TTS_OPERATION","PLAY","baidu百度tts"},4,200},{{"","TTS_OPERATION","STATE"},3,200},{{"","TTS_OPERATION","STOP"},3,50},{{"","TTS_OPERATION","DEINIT"},3,50},\

{{"","TTS_OPERATION","LOCAL_INIT","0","15","2","0"},7,50},/*{{"","TTS_OPERATION","LOCAL_STATE"},3,200},*/{{"","TTS_OPERATION","LOCAL_PLAY","baidu百度tts123456离线tts6986324"},3,2000},/*{{"","TTS_OPERATION","LOCAL_STATE"},3,200},*/{{"","TTS_OPERATION","LOCAL_STOP"},3,50},{{"","TTS_OPERATION","LOCAL_DEINIT"},3,50},\
{{"","TTS_OPERATION","LOCAL_INIT","1","14","2","1"},7,50},{{"","TTS_OPERATION","LOCAL_PLAY","baidu百度tts123456"},3,200},{{"","TTS_OPERATION","LOCAL_STOP"},3,50},{{"","TTS_OPERATION","LOCAL_DEINIT"},3,50},\
{{"","TTS_OPERATION","LOCAL_INIT","2","13","2","2"},7,50},{{"","TTS_OPERATION","LOCAL_PLAY","baidu百度tts123456"},3,200},{{"","TTS_OPERATION","LOCAL_STOP"},3,50},{{"","TTS_OPERATION","LOCAL_DEINIT"},3,50},\
{{"","TTS_OPERATION","LOCAL_INIT","3","12","2","0"},7,50},{{"","TTS_OPERATION","LOCAL_PLAY","baidu百度tts123456"},3,200},{{"","TTS_OPERATION","LOCAL_STOP"},3,50},{{"","TTS_OPERATION","LOCAL_DEINIT"},3,50},\
{{"","TTS_OPERATION","LOCAL_INIT","4","11","2","1"},7,50},{{"","TTS_OPERATION","LOCAL_PLAY","baidu百度tts123456离线tts6986324"},3,2000},{{"","TTS_OPERATION","LOCAL_STOP"},3,50},{{"","TTS_OPERATION","LOCAL_DEINIT"},3,50},\
{{"","TTS_OPERATION","LOCAL_INIT","5","10","2","2"},7,50},{{"","TTS_OPERATION","LOCAL_PLAY","baidu百度tts123456"},3,200},{{"","TTS_OPERATION","LOCAL_STOP"},3,50},{{"","TTS_OPERATION","LOCAL_DEINIT"},3,50},\
{{"","TTS_OPERATION","LOCAL_INIT","6","9","2","0"},7,50},{{"","TTS_OPERATION","LOCAL_PLAY","baidu百度tts123456"},3,200},{{"","TTS_OPERATION","LOCAL_STOP"},3,50},{{"","TTS_OPERATION","LOCAL_DEINIT"},3,50},\
{{"","TTS_OPERATION","LOCAL_INIT","7","8","2","1"},7,50},{{"","TTS_OPERATION","LOCAL_PLAY","baidu百度tts123456"},3,200},{{"","TTS_OPERATION","LOCAL_STOP"},3,50},{{"","TTS_OPERATION","LOCAL_DEINIT"},3,50},\
{{"","TTS_OPERATION","LOCAL_INIT","8","7","2","2"},7,50},{{"","TTS_OPERATION","LOCAL_PLAY","baidu百度tts123456离线tts6986324"},3,2000},{{"","TTS_OPERATION","LOCAL_STOP"},3,50},{{"","TTS_OPERATION","LOCAL_DEINIT"},3,50},\
{{"","TTS_OPERATION","LOCAL_INIT","9","6","2","0"},7,50},{{"","TTS_OPERATION","LOCAL_PLAY","baidu百度tts123456"},3,200},{{"","TTS_OPERATION","LOCAL_STOP"},3,50},{{"","TTS_OPERATION","LOCAL_DEINIT"},3,50},\
{{"","TTS_OPERATION","LOCAL_INIT","10","5","2","1"},7,50},{{"","TTS_OPERATION","LOCAL_PLAY","baidu百度tts123456"},3,200},{{"","TTS_OPERATION","LOCAL_STOP"},3,50},{{"","TTS_OPERATION","LOCAL_DEINIT"},3,50},\
{{"","TTS_OPERATION","LOCAL_INIT","11","4","2","2"},7,50},{{"","TTS_OPERATION","LOCAL_PLAY","baidu百度tts123456"},3,200},{{"","TTS_OPERATION","LOCAL_STOP"},3,50},{{"","TTS_OPERATION","LOCAL_DEINIT"},3,50},\
{{"","TTS_OPERATION","LOCAL_INIT","12","3","2","0"},7,50},{{"","TTS_OPERATION","LOCAL_PLAY","baidu百度tts123456"},3,200},{{"","TTS_OPERATION","LOCAL_STOP"},3,50},{{"","TTS_OPERATION","LOCAL_DEINIT"},3,50},\
{{"","TTS_OPERATION","LOCAL_INIT","13","2","2","1"},7,50},{{"","TTS_OPERATION","LOCAL_PLAY","baidu百度tts123456"},3,200},{{"","TTS_OPERATION","LOCAL_STOP"},3,50},{{"","TTS_OPERATION","LOCAL_DEINIT"},3,50},\
{{"","TTS_OPERATION","LOCAL_INIT","14","1","2","2"},7,50},{{"","TTS_OPERATION","LOCAL_PLAY","baidu百度tts123456"},3,200},{{"","TTS_OPERATION","LOCAL_STOP"},3,50},{{"","TTS_OPERATION","LOCAL_DEINIT"},3,50},\
{{"","TTS_OPERATION","LOCAL_INIT","15","0","2","1"},7,50},{{"","TTS_OPERATION","LOCAL_PLAY","baidu百度tts123456"},3,200},{{"","TTS_OPERATION","LOCAL_STOP"},3,50},{{"","TTS_OPERATION","LOCAL_DEINIT"},3,50},\

{{"end"},1,0}},
};

test_suite_cmd_t test_virt_at_cmd = {
    .name = "virt_at",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_virt_at_operation,
    .suite_cmd = {{{"","VIRT_AT_OPERATION","INIT"},3,50},{{"","VIRT_AT_OPERATION","SEND","AT+CGDCONT?"},4,200},{{"","VIRT_AT_OPERATION","SEND","AT+COPS?"},4,200},{{"","VIRT_AT_OPERATION","DEINIT"},3,50},\
{{"end"},1,0}},
};

test_suite_cmd_t test_wifi_cmd = {
    .name = "wifi",
    .pre_con = "none",
    .pre_exec = {{{"","","PRE_EXEC"},3,200},{{"end"},1,0}},
    .pre_func = NULL,
    .suite_func = cm_test_wifi_operation,
    .suite_cmd = {{{"","WIFI_OPERATION","CFG","3","10","60","1"},7,50},{{"","WIFI_OPERATION","START"},3,4000},{{"","WIFI_OPERATION","STOP"},3,50},{{"","WIFI_OPERATION","QUERY"},3,50},\
{{"end"},1,0}},
};


test_cmd_t test_cmd_vector[] = {
    {"ADC_OPERATION",cm_test_adc_operation},//CM:ADC_OPERATION:...
//    {"ALIYUN_OPERATION",cm_test_aliyun_operation},//CM:ALIYUN_OPERATION:...
//   {"ALIYUN_OTA_OPERATION",cm_test_aliyun_ota_operation},//CM:ALIYUN_OTA_OPERATION:...
//    {"CYCLEQUEUE_OPERATION",cm_test_cyclequeue_operation},//CM:CYCLEQUEUE_OPERATION:...
//     {"ALARM_OPERATION",cm_test_alarm_operation},//CM:ALARM_OPERATION:...
//   {"AUDIO_OPERATION",cm_test_audio_operation},//CM:AUDIO_OPERATION:...
//    {"ELOOP_OPERATION",cm_test_eloop_operation},//CM:ELOOP_OPERATION:...
//    {"ASOCKET_OPERATION",cm_test_asocket_operation},//CM:ASOCKET_OPERATION:...
//     {"ETIMER_OPERATION",cm_test_etimer_operation},//CM:ETIMER_OPERATION:...
//    {"ASYNC_DNS_OPERATION",cm_test_async_dns_operation},//CM:ASYNC_DNS_OPERATION:...
//     {"BLE_OPERATION",cm_test_ble_operation},//CM:BLE_OPERATION:...
//     {"CAMERA_OPERATION",cm_test_camera_operation},//CM:CAMERA_OPERATION:...
//     {"QR_OPERATION",cm_test_qr_operation},//CM:QR_OPERATION:...
//     {"DM_OPERATION",cm_test_dm_operation},//CM:DM_OPERATION:...
//    {"FS_OPERATION",cm_test_fs_operation},//CM:FS_OPERATION:...
//    {"FTP_OPERATION",cm_test_ftp_operation},//CM:FTP_OPERATION:...
//    {"GPIO_OPERATION",cm_test_gpio_operation},//CM:GPIO_OPERATION:...
//    {"GNSS_OPERATION",cm_test_gnss_operation},//CM:GNSS_OPERATION:...
//    {"HTTP_OPERATION",cm_test_http_operation},//CM:HTTP_OPERATION:...
//    {"I2C_OPERATION",cm_test_i2c_operation},//CM:I2C_OPERATION:...
//    {"IOMUX_OPERATION",cm_test_iomux_operation},//CM:IOMUX_OPERATION:...
//    {"KEYPAD_OPERATION",cm_test_keypad_operation},//CM:KEYPAD_OPERATION:...
//    {"LBS_OPERATION",cm_test_lbs_operation},//CM:LBS_OPERATION:...
//    {"LCD_OPERATION",cm_test_lcd_operation},//CM:LCD_OPERATION:...
    {"MEM_OPERATION",cm_test_mem_operation},//CM:MEM_OPERATION:...
//    {"MISC_OPERATION",cm_test_misc_operation},//CM:MISC_OPERATION:...
    {"MODEM_OPERATION",cm_test_modem_operation},//CM:MODEM_OPERATION:...
    {"MODEM_INFO_OPERATION",cm_test_modem_info_operation},//CM:MODEM_INFO_OPERATION:...
//    {"MQTT_OPERATION",cm_test_mqtt_operation},//CM:MQTT_OPERATION:...
//    {"NTP_OPERATION",cm_test_ntp_operation},//CM:NTP_OPERATION:...
    {"OS_OPERATION",cm_test_os_operation},//CM:OS_OPERATION:...
//    {"OTA_OPERATION",cm_test_ota_operation},//CM:OTA_OPERATION:...
//    {"PWM_OPERATION",cm_test_pwm_operation},//CM:PWM_OPERATION:...
//    {"RTC_OPERATION",cm_test_rtc_operation},//CM:RTC_OPERATION:...
//    {"SD_OPERATION",cm_test_sd_operation},//CM:SD_OPERATION:...
//    {"SIM_OPERATION",cm_test_sim_operation},//CM:SIM_OPERATION:...
//    {"SPI_OPERATION",cm_test_spi_operation},//CM:SPI_OPERATION:...
//    {"SSL_OPERATION",cm_test_ssl_operation},//CM:SSL_OPERATION:...
//    {"SUITE_OPERATION",cm_test_suite_operation},//CM:SUITE_OPERATION:...
//    {"SYS_OPERATION",cm_test_sys_operation},//CM:SYS_OPERATION:...
//   {"TTS_OPERATION",cm_test_tts_operation},//CM:TTS_OPERATION:...
//   {"USB_OPERATION",cm_test_usb_operation},//CM:USB_OPERATION:...
//   {"UART_CFG",cm_test_uart_cfg},//CM:UART_CFG:...
//   {"UART_OPERATION",cm_test_uart_operation},//CM:UART_OPERATION:...
//    {"CALL_CONTROL_OPERATION",cm_test_call_control_operation},//CM:CALL_CONTROL_OPERATION:...
//    {"SMS_OPERATION",cm_test_sms_operation},//CM:SMS_OPERATION:...
//   {"OTHER",cm_test_other_operation},//CM:OTHER:...
//   {"PM_OPERATION",cm_test_pm_operation},//CM:PM_OPERATION:...
//   {"WIFI_OPERATION",cm_test_wifi_operation},//CM:WIFI_OPERATION
    {"VIRT_AT_OPERATION",cm_test_virt_at_operation},//CM:VIRT_AT_OPERATION:...
    ///结束
};

test_suite_cmd_t  *test_suite_cmd[] = {
/*************ML307A GCLN******************/
    // &test_adc_cmd,
    // &test_aliyun_cmd,//测试代码创建线程(两次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    // &test_asocket_cmd,//测试代码创建线程(一次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    // &test_async_dns_cmd,//测试代码创建线程(一次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    // &test_eloop_cmd,
    &test_fs_cmd,
    // &test_http_cmd,
    // &test_iomux_cmd,
    &test_mem_cmd,
    &test_modem_cmd,
    &test_modem_info_cmd,
    // &test_mqtt_cmd,
    // &test_ntp_cmd,
    &test_os_cmd,//测试代码创建线程(多次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    // &test_rtc_cmd,
    // &test_sim_cmd,
    // &test_ssl_cmd,
    // &test_sys_cmd,
    // &test_tts_cmd,
    &test_virt_at_cmd,//测试代码创建线程(一次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    &test_wifi_cmd,

/*************ML307A DCLN******************/
    // &test_adc_cmd,
//    &test_aliyun_cmd,//测试代码创建线程(两次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    // &test_asocket_cmd,//测试代码创建线程(一次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    // &test_async_dns_cmd,//测试代码创建线程(一次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    // &test_eloop_cmd,
    // &test_fs_cmd,
    // &test_http_cmd,
    // &test_iomux_cmd,
    // &test_lbs_cmd,
    // &test_mem_cmd,
    // &test_modem_cmd,
    // &test_modem_info_cmd,
    // &test_mqtt_cmd,
    // &test_ntp_cmd,
    // &test_os_cmd,//测试代码创建线程(多次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    // &test_rtc_cmd,
    // &test_sim_cmd,
    // &test_ssl_cmd,
    // &test_sys_cmd,
    // &test_tts_cmd,
    // &test_virt_at_cmd,//测试代码创建线程(一次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
//    &test_wifi_cmd,

/*************ML307A DSLN******************/
//     // &test_adc_cmd,
//     // &test_aliyun_cmd,//测试代码创建线程(两次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
//     // &test_asocket_cmd,//测试代码创建线程(一次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
//     // &test_async_dns_cmd,//测试代码创建线程(一次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
//     &test_audio_play_cmd,
//     &test_audio_recorder_cmd,
//     &test_eloop_cmd,
//     &test_fs_cmd,
//     &test_ftp_cmd,
// //    &test_http_cmd,
//     &test_iomux_cmd,
//     &test_lbs_cmd,
//     &test_mem_cmd,
//     &test_modem_cmd,
//     &test_modem_info_cmd,
//     &test_mqtt_cmd,
//     &test_ntp_cmd,
//     // &test_os_cmd,//测试代码创建线程(多次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
//     // &test_rtc_cmd,
//     &test_sd_cmd,
//     &test_sim_cmd,
//     &test_ssl_cmd,
//     &test_sys_cmd,
//     &test_tts_cmd,
//     &test_virt_at_cmd,//测试代码创建线程(一次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
//     // &test_wifi_cmd,


/*************ML307A GSLN******************/
    // &test_adc_cmd,
    // &test_aliyun_cmd,//测试代码创建线程(两次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    // &test_asocket_cmd,//测试代码创建线程(一次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    // &test_async_dns_cmd,//测试代码创建线程(一次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    // &test_audio_play_cmd,
    // &test_audio_recorder_cmd,
    // &test_eloop_cmd,
    // &test_fs_cmd,
    // &test_ftp_cmd,
    // &test_http_cmd,
    // &test_iomux_cmd,
    // &test_lbs_cmd,
    // &test_mem_cmd,
    // &test_modem_cmd,
    // &test_modem_info_cmd,
    // &test_mqtt_cmd,
    // &test_ntp_cmd,
    // &test_os_cmd,//测试代码创建线程(多次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    // &test_rtc_cmd,
    // &test_sd_cmd,
    // &test_sim_cmd,
    // &test_ssl_cmd,
    // &test_sys_cmd,
    // &test_tts_cmd,
    // &test_virt_at_cmd,//测试代码创建线程(一次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    // &test_wifi_cmd,

/*************ML305A DC******************/
    // &test_adc_cmd,
    // &test_aliyun_cmd,//测试代码创建线程(两次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    // &test_asocket_cmd,//测试代码创建线程(一次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    // &test_async_dns_cmd,//测试代码创建线程(一次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    // &test_eloop_cmd,
    // &test_fs_cmd,
    // &test_ftp_cmd,
    // &test_http_cmd,
    // &test_iomux_cmd,
    // &test_lbs_cmd,
    // &test_mem_cmd,
    // &test_modem_cmd,
    // &test_mqtt_cmd,
    // &test_ntp_cmd,
    // &test_os_cmd,//测试代码创建线程(多次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    // &test_rtc_cmd,
    // &test_sim_cmd,
    // &test_ssl_cmd,
    // &test_sys_cmd,
    // &test_tts_cmd,
    // &test_virt_at_cmd,//测试代码创建线程(一次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    // &test_wifi_cmd,  

/*************ML305A DS******************/
    //&test_adc_cmd,
    //&test_aliyun_cmd,//测试代码创建线程(两次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    //&test_asocket_cmd,//测试代码创建线程(一次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    //&test_async_dns_cmd,//测试代码创建线程(一次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    //&test_audio_play_cmd,
    //&test_audio_recorder_cmd,
    //&test_eloop_cmd,
    //&test_fs_cmd,
    //&test_ftp_cmd,
    //&test_http_cmd,
    //&test_iomux_cmd,
    //&test_lbs_cmd,
    //&test_mem_cmd,
    //&test_modem_cmd,
    //&test_mqtt_cmd,
    //&test_ntp_cmd,
    // &test_os_cmd,//测试代码创建线程(多次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    //&test_rtc_cmd,
    // &test_sd_cmd,
    // &test_sim_cmd,
    // &test_ssl_cmd,
    // &test_sys_cmd,
    // &test_tts_cmd,
    // &test_virt_at_cmd,//测试代码创建线程(一次)，ML307A系列线程退出时堆栈无法回收，造成内存泄漏
    // &test_wifi_cmd,  
};




static osThreadId_t cm_test_suite_thread = NULL;
static int test_suite_state = 3;
static int times = 0;
static single_test_cmd = -1;
static int run_times = 1;
static int test_start_stop = -1;
/*线程*/
void cm_test_suite_task_func(void *argument)
{
    int i = 0;

    while(1)
    {
        osDelay(5);//线程睡眠
        if(1 == test_suite_state)
        {
            if(i < sizeof(test_suite_cmd)/sizeof(test_suite_cmd[0]))
            {
                cm_demo_printf("test %s:\n",test_suite_cmd[i]->name);
                if(0 != strcmp("none",test_suite_cmd[i]->pre_con))
                {
                    cm_demo_printf("pre_exec:%s\n",test_suite_cmd[i]->pre_con);
                    for(int j = 0;j<SUITE_PRE_SIZE;j++)//最多SUITE_PRE_SIZE条执行命令
                    {
                        if(0 == strcmp("end",test_suite_cmd[i]->pre_exec[j].case_cmd[0]))
                        {
                            break;
                        }
                        cm_demo_printf("test pre_exec:");
                        for(int k = 2;k<test_suite_cmd[i]->pre_exec[j].len;k++)
                        {
                            cm_demo_printf("%s:",test_suite_cmd[i]->pre_exec[j].case_cmd[k]);
                        }
                        cm_demo_printf("\n");
                        /*添加case_cmd[1]判断，对pre_func指定值*/
                        int l = 0;
                        for (l = 0; l < (sizeof(test_cmd_vector) / sizeof(test_cmd_t)); l++)
                        {
                            if (0 == strcmp(test_suite_cmd[i]->pre_exec[j].case_cmd[1], test_cmd_vector[l].cmdstr))
                            {
                                test_suite_cmd[i]->pre_func = test_cmd_vector[l].cmdfunc;
                                break;
                            }
                        }
                        if (l >= (sizeof(test_cmd_vector) / sizeof(test_cmd_t)))
                        {
                            cm_demo_printf("CMD NOT DEFINE\n");
                            continue;
                        }
                        (test_suite_cmd[i]->pre_func)(test_suite_cmd[i]->pre_exec[j].case_cmd,test_suite_cmd[i]->pre_exec[j].len);
                        osDelay(test_suite_cmd[i]->pre_exec[j].ecec_time);
                    }
                }//执行前提条件
                for(int j = 0;j<SUITE_CMD_SIZE;j++)//最多SUITE_CMD_SIZE条执行命令
                {
                    if(0 == strcmp("end",test_suite_cmd[i]->suite_cmd[j].case_cmd[0]))
                    {
                        break;
                    }
                    cm_demo_printf("test case:");
                    for(int k = 2;k<test_suite_cmd[i]->suite_cmd[j].len;k++)
                    {
                        cm_demo_printf("%s:",test_suite_cmd[i]->suite_cmd[j].case_cmd[k]);
                    }
                    cm_demo_printf("\n");
                    /*添加case_cmd[1]判断，对suite_func指定值*/
                    int l = 0;
                    for (l = 0; l < (sizeof(test_cmd_vector) / sizeof(test_cmd_t)); l++)
                    {
                        if (0 == strcmp(test_suite_cmd[i]->suite_cmd[j].case_cmd[1], test_cmd_vector[l].cmdstr))
                        {
                            test_suite_cmd[i]->suite_func = test_cmd_vector[l].cmdfunc;
                            break;
                        }
                    }
                    if (l >= (sizeof(test_cmd_vector) / sizeof(test_cmd_t)))
                    {
                        cm_demo_printf("CMD NOT DEFINE\n");
                        continue;
                    }
                    (test_suite_cmd[i]->suite_func)(test_suite_cmd[i]->suite_cmd[j].case_cmd,test_suite_cmd[i]->suite_cmd[j].len);
                    osDelay(test_suite_cmd[i]->suite_cmd[j].ecec_time);
                }
                cm_demo_printf("\n\n\n-----------------------这是分割线--------------------------\n\n\n");
                ++i;
            }
            else
            {
                cm_test_mem_operation((unsigned char *[]){"","","HEAP"},3);//查询内存容量。
                test_suite_state = 2;
            }
        }
        else if(0 == test_suite_state || 0 == test_start_stop)
        {
            cm_demo_printf("test stop\n");
            osDelay(600);
        }
        else if(2 == test_suite_state)
        {
            cm_demo_printf("test %d end\n",run_times);
            if(run_times == times)
            {
                cm_demo_printf("all test end\n");
                test_suite_state = 0;
                // osDelay(6000000);
                goto end1;
            }
            run_times++;
            i = 0;
            osDelay(200);
            test_suite_state = 1;
end1:               ; 
        }
        else if(3 == test_suite_state)
        {
            cm_demo_printf("test %d end\n",run_times);
            if(run_times == times)
            {
                cm_demo_printf("all test end\n");
                test_suite_state = 0;
                single_test_cmd = -1;
                // osDelay(6000000);
                goto end2;
            }
            run_times++;
            osDelay(200);
            test_suite_state = 4;
end2:               ;
        }
        else if(4 == test_suite_state)
        {
            cm_demo_printf("test %s:\n",test_suite_cmd[single_test_cmd]->name);
            if(0 != strcmp("none",test_suite_cmd[single_test_cmd]->pre_con))
            {
                cm_demo_printf("pre_exec:%s\n",test_suite_cmd[single_test_cmd]->pre_con);
                for(int j = 0;j<SUITE_PRE_SIZE;j++)//最多SUITE_PRE_SIZE条执行命令
                {
                    if(0 == strcmp("end",test_suite_cmd[single_test_cmd]->pre_exec[j].case_cmd[0]))
                    {
                        break;
                    }
                    cm_demo_printf("test pre_exec:");
                    for(int k = 2;k<test_suite_cmd[single_test_cmd]->pre_exec[j].len;k++)
                    {
                        cm_demo_printf("%s:",test_suite_cmd[single_test_cmd]->pre_exec[j].case_cmd[k]);
                    }
                    cm_demo_printf("\n");
                    /*添加case_cmd[1]判断，对pre_func指定值*/
                    int l = 0;
                    for (l = 0; l < (sizeof(test_cmd_vector) / sizeof(test_cmd_t)); l++)
                    {
                        if (0 == strcmp(test_suite_cmd[single_test_cmd]->pre_exec[j].case_cmd[1], test_cmd_vector[l].cmdstr))
                        {
                            test_suite_cmd[single_test_cmd]->pre_func = test_cmd_vector[l].cmdfunc;
                            break;
                        }
                    }
                    if (l >= (sizeof(test_cmd_vector) / sizeof(test_cmd_t)))
                    {
                        cm_demo_printf("CMD NOT DEFINE\n");
                        continue;
                    }
                    (test_suite_cmd[single_test_cmd]->pre_func)(test_suite_cmd[single_test_cmd]->pre_exec[j].case_cmd,test_suite_cmd[single_test_cmd]->pre_exec[j].len);
                    osDelay(test_suite_cmd[single_test_cmd]->pre_exec[j].ecec_time);
                }
            }//执行前提条件
            for(int j = 0;j<SUITE_CMD_SIZE;j++)//最多SUITE_CMD_SIZE条执行命令
            {
                if(0 == strcmp("end",test_suite_cmd[single_test_cmd]->suite_cmd[j].case_cmd[0]))
                {
                    break;
                }
                cm_demo_printf("test case:");
                for(int k = 2;k<test_suite_cmd[single_test_cmd]->suite_cmd[j].len;k++)
                {
                    cm_demo_printf("%s:",test_suite_cmd[single_test_cmd]->suite_cmd[j].case_cmd[k]);
                }
                cm_demo_printf("\n");
                /*添加case_cmd[1]判断，对suite_func指定值*/
                int l = 0;
                for (l = 0; l < (sizeof(test_cmd_vector) / sizeof(test_cmd_t)); l++)
                {
                    if (0 == strcmp(test_suite_cmd[single_test_cmd]->suite_cmd[j].case_cmd[1], test_cmd_vector[l].cmdstr))
                    {
                        test_suite_cmd[single_test_cmd]->suite_func = test_cmd_vector[l].cmdfunc;
                        break;
                    }
                }
                if (l >= (sizeof(test_cmd_vector) / sizeof(test_cmd_t)))
                {
                    cm_demo_printf("CMD NOT DEFINE\n");
                    continue;
                }
                (test_suite_cmd[single_test_cmd]->suite_func)(test_suite_cmd[single_test_cmd]->suite_cmd[j].case_cmd,test_suite_cmd[single_test_cmd]->suite_cmd[j].len);
                osDelay(test_suite_cmd[single_test_cmd]->suite_cmd[j].ecec_time);
            }
            test_suite_state = 3;
            cm_test_mem_operation((unsigned char *[]){"","","HEAP"},3);//单个功能执行测试时查询内存容量，便于每个功能覆盖内存泄露测试。
            cm_demo_printf("\n\n\n-----------------------这是分割线--------------------------\n\n\n");
            osDelay(100);
        }

        // for(int i = 0;i < sizeof(test_suite_cmd);i++)
        // {
        //     osDelay(test_suite_cmd[i]->suite_cmd->ecec_time);

        // }
        
    }
}

void cm_test_suite_operation(unsigned char *cmd[],int len)
{
    if(0 == strcmp("start",cmd[2]))//创建线程执行测试命令
    {
        if(NULL == cm_test_suite_thread)
        {
            const osThreadAttr_t attr = {
                "test_suite_thread",   /**< name of the thread. */
                0,   /**< attribute bits. */
                NULL,    /**< memory for control block. */
                NULL,   /**< size of provided memory for control block. */
                NULL,    /**< memory for stack. */
                8912,   /**< size of stack. */
                osPriorityNormal,   /**< initial thread priority (default: osPriorityNormal). */
                0,   /**< TrustZone module identifier. */
                0,   /**< reserved (must be 0). */
            };
            char *argument = "test_suite";
            cm_test_suite_thread = osThreadNew (cm_test_suite_task_func, argument, &attr); 
            OCTEST_FUNC_EXPECT_NOT_NULL(cm_test_suite_thread,osThreadNew);
            if (NULL == cm_test_suite_thread)
            {
                cm_demo_printf("creat test suite thread fail\n");
                return;
            }
        }
        test_suite_state = 1;
        test_start_stop = 1;
        times = atoi(cmd[3]);
        run_times = 1;
        if(5 == len)
        {
            for(int k = 0;k<sizeof(test_suite_cmd)/sizeof(test_suite_cmd[0]);k++)
            {
                if(0 == strcmp(cmd[4],test_suite_cmd[k]->name))
                {
                    single_test_cmd = k;
                    test_suite_state = 4;
                    break;
                }
            }
            if(-1 == single_test_cmd)
            {
                test_suite_state = 0;
                cm_demo_printf("not find test cmd\n");
            }
        }
    }else if (0 == strcmp("stop",cmd[2]))
    {
        test_suite_state = 0;
        test_start_stop = 0;
        osThreadTerminate (cm_test_suite_thread);//终止线程
        cm_test_suite_thread = NULL;
    }
    else if (0 == strcmp("pause",cmd[2]))
    {
        osThreadSuspend (cm_test_suite_thread);//挂起线程
    }
    else if (0 == strcmp("resume",cmd[2]))
    {
        test_suite_state = 0;
        test_start_stop = 0;
        osThreadResume (cm_test_suite_thread);//恢复线程
    }
    else
    {
        cm_demo_printf("param error!\n");
    }
}
